import { Input } from "antd"
import { FC } from "react"

import { SFormItem } from "@/components/common"
import { useLocale } from "@/locales"

const SuperiorAgent: FC<any> = props => {
	const { normalize } = props
	const { formatMessage } = useLocale()
	const defaultNormalize = (value: string) => value.replaceAll(" ", "") || undefined
	return (
		<SFormItem
			normalize={normalize || defaultNormalize}
			label={formatMessage({ id: "report.rerecon_parent_proxy_name" })}
			name={"parentProxyName"}
		>
			<Input placeholder={formatMessage({ id: "common.please_enter" })} allowClear {...props} />
		</SFormItem>
	)
}

export default SuperiorAgent
